/**
 * Created by Administrator on 2017/7/27.
 */

(function (w) {
    //var apiHost='http://localhost:8081';
    //var apiHost=' http://192.168.199.107:8081';
//   var apiHost='http://develop.jhjvip.cn:8080';
    //var apiHost=' http://192.168.199.40:8081';
    //var apiHost=' http://192.168.199.104:8080';
    var apiHost='https://www.uhuijia.com.cn'
//	var apiHost='http://192.168.1.139:8080';	

    //威哥服务器
    //var apiHost=' http://192.168.199.132:8080';
    //配置项
    w.C={};
    //域名
    C.host=apiHost+'/mall/mobile/';

    //分享出去的url
    //C.share='http://192.168.199.200:3000/git/huifaShop/html/share_red_package.html';
    C.share='http://www.jhjvip.cn/gzh/html/share_red_package.html';

    //是否开启打印日志
    C.debug=true;
    //是否正在维护
    C.isWeihu=false;
    //手机验证正则
    C.phoneReg = /^(((13[0-9]{1})|(14[0-9]{1})|(15[0-9]{1})|(16[0-9]{1})|(18[0-9]{1})|(17[0-9]{1})|(19[0-9]{1}))+\d{8})$/;
    //邮箱验证正则
    C.emailReg = /^([a-zA-Z0-9]+[_|\_|\.]?)*[a-zA-Z0-9]+@([a-zA-Z0-9]+[_|\_|\.]?)*[a-zA-Z0-9]+\.[a-zA-Z]{2,3}$/;
    //安全码验证正则
    C.selfNumberReg = /^[0-9a-zA-Z]{8,16}$/;
    //发送验证码时间
    C.putCodeTime=60;


    //var token='2017091814287384479dc2fcbc776c4e34a1d9f9ad2b297b9d';
    //localStorage.setItem('token','20171031100281895655721087a24e4b68b76ec2fb9ef15ab2');
    C.token=localStorage.getItem('token');

    //强制刷新当前页面
    C.version=Math.random();

    //接口
    C.interface={
    	//京东banner
    	jdbanner:'goodspool/banners',
		//注册验证码	
    	code:'login/code',
    	//注册方法
    	register:'login/reg',
    	//精选商品
    	choisegood:'goodspool/list',
    	//登录方法
    	login : 'login/in',	
    	 //商品分类
    	categoryInter:'goodspool/categorys',
    	//商品详情
    	comdetailInter:'goodspool/detail',
    	//个人中心回显
    	peronalInter:'goodspool/uc',
    	//编辑信息
    	editperInter:'goodspool/editUc',
    	comdetailInter:'goodspool/detail',
    	//忘记密码接口
    	forgetpwd : 'users/forgetpwd',
    	//用户密码重置
    	chgpwd : 'users/chgpwd',
    	//用户头像
    	userInter:'goodspool/userInfo',
    	//二合一转链
    	erYinter:'goodspool/convert',
    	//退出
    	quitInter:'login/out'
    };
    //组合接口地址
    for (k in C.interface){
        C.interface[k]=C.host + C.interface[k];
    }


})(window);













